﻿using System.Windows.Controls;
using GalaSoft.MvvmLight.Messaging;
using Microsoft.Win32;

namespace EX_NFC.FrontEnd.Windows.Controls
{
    /// <summary>
    /// Interaction logic for DeviceLCDControl.xaml
    /// </summary>
    public partial class DeviceLCDControl
    {
        public DeviceLCDControl()
        {
            InitializeComponent();
        }

        private void Button_Click(object sender, System.Windows.RoutedEventArgs e)
        {
            var ofd = new OpenFileDialog {DefaultExt = "*.jpg", Filter = "jpeg|*.jpg"};

            if ((bool)ofd.ShowDialog())
            {
                Messenger.Default.Send(new GenericMessage<string>(ofd.FileName), MessageType.ImageSelected);
            }
        }
    }
}
